package com.ijiuchuang.jc_localization.view.adapter;

import android.content.Context;
import android.view.View;

import com.ijiuchuang.jc_localization.R;
import com.ijiuchuang.jc_localization.app.Config;
import com.ijiuchuang.jc_localization.bean.bmob.Product;
import com.ijiuchuang.jc_localization.bean.cache.DeviceListCache;
import com.ijiuchuang.jc_localization.bean.lite.Tag;
import com.ijiuchuang.jc_localization.tools.adapter.ViewHolder;
import com.ijiuchuang.jc_localization.tools.adapter.recyclerview.CommonAdapter;

import java.util.List;

/**
 * Created by Veev on 2016/6/13
 *
 * @link 384506557@qq.com
 */
public class ProductListRecyclerAdapter extends CommonAdapter<Product> {

    public ProductListRecyclerAdapter(Context context, int layoutId, List<Product> datas) {
        super(context, layoutId, datas);
    }

    @Override
    public void convert(final ViewHolder holder, final Product product) {
        holder.setText(R.id.recycler_item_product_list_text_name, product.getName());
        holder.setImageByUrl(R.id.recycler_item_product_list_image, product.getPic().getUrl());
    }
}
